<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
</head>
<body>
<script>
    function Person(){
       this.name = "小明",
       this.age = 18,
       this.sex = "男"

    }
    Person.prototype.show = function () {
            console.log(this.name+"今年"+this.age+"性别"+this.sex+"有男朋友，会说话， 说我是你的男朋友！");
    }
    var str = new Person();
    str.show();
</script>
</body>
</html>